//
//  LSZAudioRearchTableViewCell.m
//  JKFuYinProject
//
//  Created by 九酷 on 2018/4/13.
//  Copyright © 2018年 LC. All rights reserved.
//

#import "LSZAudioRearchTableViewCell.h"

@implementation LSZAudioRearchTableViewCell

-(id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.labelNumber =[[UILabel alloc]init];
        self.labelNumber.textColor = lightColor;
        self.labelNumber.textAlignment = NSTextAlignmentCenter;
        [self addSubview:self.labelNumber];
        if(ScreenWidth >=375){
            self.labelNumber.frame = CGRectMake(0, 0, 40, 70);
            self.labelNumber.font = FONT_17;
        }else{
            self.labelNumber.frame = CGRectMake(0,0, 40, 60);
            self.labelNumber.font = FONT_14;
        }
        self.lableTitle = [[UILabel alloc]initWithFrame:CGRectMake(CGRectGetMaxX(self.labelNumber.frame), 12, WidthScal750(480)-25, 17)];
        self.lableTitle.textColor = titleColorLSZ;
        [self addSubview:self.lableTitle];
        if(ScreenWidth >=375){
            self.lableTitle.font = FONT_17;
            self.lableTitle.frame = CGRectMake(CGRectGetMaxX(self.labelNumber.frame), 11, WidthScal750(480)-29,21);
        }else{
            self.lableTitle.font = FONT_14;
            self.lableTitle.frame = CGRectMake(CGRectGetMaxX(self.labelNumber.frame), 12, WidthScal750(480)-25, 17);
        }
        self.labelIntroduce = [[UILabel alloc]init];
        self.labelIntroduce.textColor = lightColor;
        [self addSubview:self.labelIntroduce];
        if(ScreenWidth >=375){
            self.labelIntroduce.font = FONT_14;
            self.labelIntroduce.frame = CGRectMake(CGRectGetMaxX(self.labelNumber.frame), CGRectGetMaxY(self.lableTitle.frame)+9, WidthScal750(480),17);
        }else{
            self.labelIntroduce.font = FONT_12;
            self.labelIntroduce.frame = CGRectMake(CGRectGetMaxX(self.labelNumber.frame), CGRectGetMaxY(self.lableTitle.frame)+6, WidthScal750(480), 13);
        }
        self.imageJi = [[UIImageView alloc]init];
        self.imageJi.image = [UIImage imageNamed:@"耳机_次数"];
        [self addSubview:self.imageJi];
        if(ScreenWidth >=375){
            self.imageJi.frame = CGRectMake(ScreenWidth-19-60+30,14,17,17);
        }else{
            self.imageJi.frame = CGRectMake(ScreenWidth-19-60+30,15,15,15);

        }
        self.labelClick = [[UILabel alloc]init];
        self.labelClick.textColor = lightColor;
        self.labelClick.textAlignment = NSTextAlignmentCenter;
        [self addSubview:self.labelClick];
        if(ScreenWidth >=375){
            self.labelClick.font = FONT_15;
            self.labelClick.frame = CGRectMake(ScreenWidth-19-60,CGRectGetMaxY(self.imageJi.frame)+8,19+57,15);
        }else{
            self.labelClick.font = FONT_12;
            self.labelClick.frame = CGRectMake(ScreenWidth-19-60,CGRectGetMaxY(self.imageJi.frame)+3,19+57,15);
        }
    }
    return self;
}
///是否是选中当前这首  ,  为主题颜色
- (void)didSelectRowCellWithIsSystemRed:(BOOL)isSystemRed {
    if (isSystemRed) {
        self.lableTitle.textColor  = RGBColor(238, 82, 74);
        self.labelIntroduce.textColor= RGBColor(238, 82, 74);
        self.labelClick.textColor = RGBColor(238, 82, 74);
        self.imageJi.image = [UIImage imageNamed:@"耳机_红"];
    }else{
        self.lableTitle.textColor  = titleColorLSZ;
        self.labelIntroduce.textColor= lightColor;
        self.labelClick.textColor = lightColor;
        self.imageJi.image = [UIImage imageNamed:@"耳机_次数"];
    }
}
@end
